package com.zygh.policeasset.mapper;

import com.zygh.policeasset.pojo.OperaLog;
import java.util.List;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Result;
import org.apache.ibatis.annotations.Results;
import org.apache.ibatis.annotations.Select;

@Mapper
/* loaded from: police-asset-2.0-0.0.1-SNAPSHOT.jar:BOOT-INF/classes/com/zygh/policeasset/mapper/OperaLogMapper.class */
public interface OperaLogMapper {
    @Insert({"insert into opera_log (oper_modul,oper_type,oper_desc,oper_requ_param,oper_resp_param,oper_user_id,oper_user_name,oper_method,oper_uri,oper_ip,oper_create_time) values (#{operModul},#{operType},#{operDesc},#{operRequParam},#{operRespParam},#{operUserId},#{operUserName},#{operMethod},#{operUri},#{operIp},#{operCreateTime})"})
    Integer insert(OperaLog operaLog);

    @Select({"<script>select * from opera_log  <where><if test='operIp != null and operIp.length &gt; 0 '> oper_ip = #{operIp}</if><if test='operUserName != null and operUserName.length &gt; 0 '> oper_user_name = #{operUserName}</if><if test='startTime != null and startTime.length &gt; 0 and endTime != null and endTime.length &gt; 0'>and oper_create_time between #{startTime}  and  #{endTime}</if> </where> order by id desc </script>"})
    @Results({@Result(property = "operModul", column = "oper_modul"), @Result(property = "operType", column = "oper_type"), @Result(property = "operDesc", column = "oper_desc"), @Result(property = "operRequParam", column = "oper_requ_param"), @Result(property = "operRespParam", column = "oper_resp_param"), @Result(property = "operUserId", column = "oper_user_id"), @Result(property = "operUserName", column = "oper_user_name"), @Result(property = "operMethod", column = "oper_method"), @Result(property = "operUri", column = "oper_uri"), @Result(property = "operIp", column = "oper_ip"), @Result(property = "operCreateTime", column = "oper_create_time")})
    List<OperaLog> findAll(@Param("operIp") String str, @Param("operUserName") String str2, @Param("startTime") String str3, @Param("endTime") String str4);
}